/**
 * Copyright (c) 2000-2011 Liferay, Inc. All rights reserved.
 *
 * This library is free software; you can redistribute it and/or modify it under
 * the terms of the GNU Lesser General Public License as published by the Free
 * Software Foundation; either version 2.1 of the License, or (at your option)
 * any later version.
 *
 * This library is distributed in the hope that it will be useful, but WITHOUT
 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
 * FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
 * details.
 */

package doan.quanlycanbo.portlet.service;

import com.liferay.portal.kernel.bean.PortletBeanLocatorUtil;
import com.liferay.portal.kernel.util.ClassLoaderProxy;

/**
 * The utility for the hoso local service. This utility wraps {@link doan.quanlycanbo.portlet.service.impl.hosoLocalServiceImpl} and is the primary access point for service operations in application layer code running on the local server.
 *
 * <p>
 * Never modify this class directly. Add custom service methods to {@link doan.quanlycanbo.portlet.service.impl.hosoLocalServiceImpl} and rerun ServiceBuilder to regenerate this class.
 * </p>
 *
 * <p>
 * This is a local service. Methods of this service will not have security checks based on the propagated JAAS credentials because this service can only be accessed from within the same VM.
 * </p>
 *
 * @author Nguyen Tuan Vinh
 * @see hosoLocalService
 * @see doan.quanlycanbo.portlet.service.base.hosoLocalServiceBaseImpl
 * @see doan.quanlycanbo.portlet.service.impl.hosoLocalServiceImpl
 * @generated
 */
public class hosoLocalServiceUtil {
	/**
	* Adds the hoso to the database. Also notifies the appropriate model listeners.
	*
	* @param hoso the hoso to add
	* @return the hoso that was added
	* @throws SystemException if a system exception occurred
	*/
	public static doan.quanlycanbo.portlet.model.hoso addhoso(
		doan.quanlycanbo.portlet.model.hoso hoso)
		throws com.liferay.portal.kernel.exception.SystemException {
		return getService().addhoso(hoso);
	}

	/**
	* Creates a new hoso with the primary key. Does not add the hoso to the database.
	*
	* @param mahoso the primary key for the new hoso
	* @return the new hoso
	*/
	public static doan.quanlycanbo.portlet.model.hoso createhoso(long mahoso) {
		return getService().createhoso(mahoso);
	}

	/**
	* Deletes the hoso with the primary key from the database. Also notifies the appropriate model listeners.
	*
	* @param mahoso the primary key of the hoso to delete
	* @throws PortalException if a hoso with the primary key could not be found
	* @throws SystemException if a system exception occurred
	*/
	public static void deletehoso(long mahoso)
		throws com.liferay.portal.kernel.exception.PortalException,
			com.liferay.portal.kernel.exception.SystemException {
		getService().deletehoso(mahoso);
	}

	/**
	* Deletes the hoso from the database. Also notifies the appropriate model listeners.
	*
	* @param hoso the hoso to delete
	* @throws SystemException if a system exception occurred
	*/
	public static void deletehoso(doan.quanlycanbo.portlet.model.hoso hoso)
		throws com.liferay.portal.kernel.exception.SystemException {
		getService().deletehoso(hoso);
	}

	/**
	* Performs a dynamic query on the database and returns the matching rows.
	*
	* @param dynamicQuery the dynamic query to search with
	* @return the matching rows
	* @throws SystemException if a system exception occurred
	*/
	@SuppressWarnings("rawtypes")
	public static java.util.List dynamicQuery(
		com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery)
		throws com.liferay.portal.kernel.exception.SystemException {
		return getService().dynamicQuery(dynamicQuery);
	}

	/**
	* Performs a dynamic query on the database and returns a range of the matching rows.
	*
	* <p>
	* Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set.
	* </p>
	*
	* @param dynamicQuery the dynamic query to search with
	* @param start the lower bound of the range of model instances to return
	* @param end the upper bound of the range of model instances to return (not inclusive)
	* @return the range of matching rows
	* @throws SystemException if a system exception occurred
	*/
	@SuppressWarnings("rawtypes")
	public static java.util.List dynamicQuery(
		com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, int start,
		int end) throws com.liferay.portal.kernel.exception.SystemException {
		return getService().dynamicQuery(dynamicQuery, start, end);
	}

	/**
	* Performs a dynamic query on the database and returns an ordered range of the matching rows.
	*
	* <p>
	* Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set.
	* </p>
	*
	* @param dynamicQuery the dynamic query to search with
	* @param start the lower bound of the range of model instances to return
	* @param end the upper bound of the range of model instances to return (not inclusive)
	* @param orderByComparator the comparator to order the results by
	* @return the ordered range of matching rows
	* @throws SystemException if a system exception occurred
	*/
	@SuppressWarnings("rawtypes")
	public static java.util.List dynamicQuery(
		com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, int start,
		int end,
		com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
		throws com.liferay.portal.kernel.exception.SystemException {
		return getService()
				   .dynamicQuery(dynamicQuery, start, end, orderByComparator);
	}

	/**
	* Counts the number of rows that match the dynamic query.
	*
	* @param dynamicQuery the dynamic query to search with
	* @return the number of rows that match the dynamic query
	* @throws SystemException if a system exception occurred
	*/
	public static long dynamicQueryCount(
		com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery)
		throws com.liferay.portal.kernel.exception.SystemException {
		return getService().dynamicQueryCount(dynamicQuery);
	}

	/**
	* Gets the hoso with the primary key.
	*
	* @param mahoso the primary key of the hoso to get
	* @return the hoso
	* @throws PortalException if a hoso with the primary key could not be found
	* @throws SystemException if a system exception occurred
	*/
	public static doan.quanlycanbo.portlet.model.hoso gethoso(long mahoso)
		throws com.liferay.portal.kernel.exception.PortalException,
			com.liferay.portal.kernel.exception.SystemException {
		return getService().gethoso(mahoso);
	}

	/**
	* Gets a range of all the hosos.
	*
	* <p>
	* Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set.
	* </p>
	*
	* @param start the lower bound of the range of hosos to return
	* @param end the upper bound of the range of hosos to return (not inclusive)
	* @return the range of hosos
	* @throws SystemException if a system exception occurred
	*/
	public static java.util.List<doan.quanlycanbo.portlet.model.hoso> gethosos(
		int start, int end)
		throws com.liferay.portal.kernel.exception.SystemException {
		return getService().gethosos(start, end);
	}

	/**
	* Gets the number of hosos.
	*
	* @return the number of hosos
	* @throws SystemException if a system exception occurred
	*/
	public static int gethososCount()
		throws com.liferay.portal.kernel.exception.SystemException {
		return getService().gethososCount();
	}

	/**
	* Updates the hoso in the database. Also notifies the appropriate model listeners.
	*
	* @param hoso the hoso to update
	* @return the hoso that was updated
	* @throws SystemException if a system exception occurred
	*/
	public static doan.quanlycanbo.portlet.model.hoso updatehoso(
		doan.quanlycanbo.portlet.model.hoso hoso)
		throws com.liferay.portal.kernel.exception.SystemException {
		return getService().updatehoso(hoso);
	}

	/**
	* Updates the hoso in the database. Also notifies the appropriate model listeners.
	*
	* @param hoso the hoso to update
	* @param merge whether to merge the hoso with the current session. See {@link com.liferay.portal.service.persistence.BatchSession#update(com.liferay.portal.kernel.dao.orm.Session, com.liferay.portal.model.BaseModel, boolean)} for an explanation.
	* @return the hoso that was updated
	* @throws SystemException if a system exception occurred
	*/
	public static doan.quanlycanbo.portlet.model.hoso updatehoso(
		doan.quanlycanbo.portlet.model.hoso hoso, boolean merge)
		throws com.liferay.portal.kernel.exception.SystemException {
		return getService().updatehoso(hoso, merge);
	}

	public static java.util.List<doan.quanlycanbo.portlet.model.hoso> getAll()
		throws com.liferay.portal.kernel.exception.SystemException {
		return getService().getAll();
	}

	public static doan.quanlycanbo.portlet.model.hoso getByPrimaryKey(
		long idHoso)
		throws com.liferay.portal.kernel.exception.SystemException,
			doan.quanlycanbo.portlet.NoSuchhosoException {
		return getService().getByPrimaryKey(idHoso);
	}

	public static java.util.List<doan.quanlycanbo.portlet.model.hoso> getByDonVi(
		long madonvi)
		throws com.liferay.portal.kernel.exception.SystemException {
		return getService().getByDonVi(madonvi);
	}

	public static java.util.List<doan.quanlycanbo.portlet.model.hoso> getByChucVu(
		long machucvu)
		throws com.liferay.portal.kernel.exception.SystemException {
		return getService().getByChucVu(machucvu);
	}

	public static java.util.List<doan.quanlycanbo.portlet.model.hoso> getByHocHam(
		long mahocham)
		throws com.liferay.portal.kernel.exception.SystemException {
		return getService().getByHocHam(mahocham);
	}

	public static java.util.List<doan.quanlycanbo.portlet.model.hoso> getByHocVi(
		long mahocvi)
		throws com.liferay.portal.kernel.exception.SystemException {
		return getService().getByHocVi(mahocvi);
	}

	public static java.util.List<doan.quanlycanbo.portlet.model.hoso> getByCapUY(
		long macapuy)
		throws com.liferay.portal.kernel.exception.SystemException {
		return getService().getByCapUY(macapuy);
	}

	public static java.util.List<doan.quanlycanbo.portlet.model.hoso> getByDanhHieu(
		long madanhhieu)
		throws com.liferay.portal.kernel.exception.SystemException {
		return getService().getByDanhHieu(madanhhieu);
	}

	public static java.util.List<doan.quanlycanbo.portlet.model.hoso> getByDanToc(
		long madantoc)
		throws com.liferay.portal.kernel.exception.SystemException {
		return getService().getByDanToc(madantoc);
	}

	public static java.util.List<doan.quanlycanbo.portlet.model.hoso> getByTonGiao(
		long matongiao)
		throws com.liferay.portal.kernel.exception.SystemException {
		return getService().getByTonGiao(matongiao);
	}

	public static java.util.List<doan.quanlycanbo.portlet.model.hoso> getByXuatThan(
		long maxuatthan)
		throws com.liferay.portal.kernel.exception.SystemException {
		return getService().getByXuatThan(maxuatthan);
	}

	public static java.util.List<doan.quanlycanbo.portlet.model.hoso> getByGDPT(
		long magdpt) throws com.liferay.portal.kernel.exception.SystemException {
		return getService().getByGDPT(magdpt);
	}

	public static java.util.List<doan.quanlycanbo.portlet.model.hoso> getByHeSoLuong(
		long mahsl) throws com.liferay.portal.kernel.exception.SystemException {
		return getService().getByHeSoLuong(mahsl);
	}

	public static java.lang.String getHH_HV(long maHoso)
		throws com.liferay.portal.kernel.exception.PortalException,
			com.liferay.portal.kernel.exception.SystemException {
		return getService().getHH_HV(maHoso);
	}

	public static doan.quanlycanbo.portlet.model.hoso addHoso(long groupId,
		long companyId, java.lang.String languageId, long userId,
		long sohieunv, java.lang.String cmtnd, java.lang.String hoten,
		java.lang.String gioitinh, java.lang.String tenthuongdung,
		java.util.Date ngaysinh, java.lang.String noisinh,
		java.lang.String quequan, java.lang.String diachithuongtru,
		java.lang.String diachitamtru, java.lang.String dienthoai,
		java.lang.String email, java.lang.String quocgia,
		java.util.Date ngayVaoDang, java.lang.String cntn1, int namtn1,
		java.lang.String cntn2, int namtn2, java.lang.String cntn3, int namtn3,
		long madonvi, long machucvu, long madantoc, long mahocham,
		long mahocvi, long mahesoluong, long macapuy, long matongiao,
		long maxuatthan, long magdpt, long madanhhieu, int vitri)
		throws com.liferay.portal.kernel.exception.SystemException {
		return getService()
				   .addHoso(groupId, companyId, languageId, userId, sohieunv,
			cmtnd, hoten, gioitinh, tenthuongdung, ngaysinh, noisinh, quequan,
			diachithuongtru, diachitamtru, dienthoai, email, quocgia,
			ngayVaoDang, cntn1, namtn1, cntn2, namtn2, cntn3, namtn3, madonvi,
			machucvu, madantoc, mahocham, mahocvi, mahesoluong, macapuy,
			matongiao, maxuatthan, magdpt, madanhhieu, vitri);
	}

	public static doan.quanlycanbo.portlet.model.hoso updateHoso(long maHoso,
		long sohieunv, java.lang.String cmtnd, java.lang.String hoten,
		java.lang.String gioitinh, java.lang.String tenthuongdung,
		java.util.Date ngaysinh, java.lang.String noisinh,
		java.lang.String quequan, java.lang.String diachithuongtru,
		java.lang.String diachitamtru, java.lang.String dienthoai,
		java.lang.String email, java.lang.String quocgia,
		java.util.Date ngayvaodang, java.lang.String cntn1, int namtncn1,
		java.lang.String cntn2, int namtncn2, java.lang.String cntn3,
		int namtncn3, long madonvi, long machucvu, long madantoc,
		long mahocham, long mahocvi, long mahesoluong, long macapuy,
		long matongiao, long maxuatthan, long magdpt, long madanhhieu, int vitri)
		throws com.liferay.portal.kernel.exception.SystemException,
			doan.quanlycanbo.portlet.NoSuchhosoException {
		return getService()
				   .updateHoso(maHoso, sohieunv, cmtnd, hoten, gioitinh,
			tenthuongdung, ngaysinh, noisinh, quequan, diachithuongtru,
			diachitamtru, dienthoai, email, quocgia, ngayvaodang, cntn1,
			namtncn1, cntn2, namtncn2, cntn3, namtncn3, madonvi, machucvu,
			madantoc, mahocham, mahocvi, mahesoluong, macapuy, matongiao,
			maxuatthan, magdpt, madanhhieu, vitri);
	}

	public static void deleteHoso(long maHoso)
		throws com.liferay.portal.kernel.exception.PortalException,
			com.liferay.portal.kernel.exception.SystemException {
		getService().deleteHoso(maHoso);
	}

	public static void deleteHoso(doan.quanlycanbo.portlet.model.hoso hosoDel)
		throws com.liferay.portal.kernel.exception.PortalException,
			com.liferay.portal.kernel.exception.SystemException {
		getService().deleteHoso(hosoDel);
	}

	public static void clearService() {
		_service = null;
	}

	public static hosoLocalService getService() {
		if (_service == null) {
			Object obj = PortletBeanLocatorUtil.locate(ClpSerializer.SERVLET_CONTEXT_NAME,
					hosoLocalService.class.getName());
			ClassLoader portletClassLoader = (ClassLoader)PortletBeanLocatorUtil.locate(ClpSerializer.SERVLET_CONTEXT_NAME,
					"portletClassLoader");

			ClassLoaderProxy classLoaderProxy = new ClassLoaderProxy(obj,
					portletClassLoader);

			_service = new hosoLocalServiceClp(classLoaderProxy);

			ClpSerializer.setClassLoader(portletClassLoader);
		}

		return _service;
	}

	public void setService(hosoLocalService service) {
		_service = service;
	}

	private static hosoLocalService _service;
}